package com.itheima.App;

import com.itheima.Dao.BookDao;
import com.itheima.SpringConfig.StringConfig;
import org.springframework.context.ApplicationContext;
import org.springframework.context.annotation.AnnotationConfigApplicationContext;

public class SpringConfigtest {
    public static void main(String[] args) {
        ApplicationContext ctx = new AnnotationConfigApplicationContext(StringConfig.class);
        BookDao bookDao =(BookDao) ctx.getBean(BookDao.class);
        bookDao.save();
    }
}
